/**
 * Sample React Native App
 * https://github.com/facebook/react-native
 *
 * @format
 */

import type {PropsWithChildren} from 'react';
import {DetailsScreen} from './robot01/details';
import { createStaticNavigation,useNavigation } from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';

import { Provider } from 'react-redux';
import {store} from './redux/store'; // 引入 Redux Store
import { NativeBaseProvider, Box, Button,Center } from "native-base";
import {  Provider as Provider2, Toast } from '@ant-design/react-native';


import {
  StyleSheet,
} from 'react-native';


type SectionProps = PropsWithChildren<{
  title: string;
}>;



const RootStack = createNativeStackNavigator({
  initialRouteName: 'DetailsScreen',
  
  screens: {
    DetailsScreen:{
      screen:DetailsScreen,
      options: {
        orientation:"landscape",
        // headerTitle : "111",
        // statusBarHidden : true,
        statusBarAnimation: "none",
        // https://reactnavigation.org/docs/native-stack-navigator/#options
        animation: "none",
        // animation: "slide_from_bottom",  slide_from_right  slide_from_left
        headerShown: false,
        // cardStyleInterpolator: CardStyleInterpolators.forBottomSheetAndroid,
        // transitionSpec: {
        //   open: {
        //     animation: 'spring',  // 使用 spring 动画
        //     config: {
        //       stiffness: 300,
        //       damping: 25,
        //       mass: 1,
        //     },
        //   },
        // }
        // title: 'DetailsScreen',
      },

    }
     ,
  },
});

const Navigation = createStaticNavigation(RootStack);

function App01() {
  return   <Provider store={store}>
    <NativeBaseProvider>
      <Provider2>
    <Navigation />
    </Provider2>
    </NativeBaseProvider>
</Provider>
}


const styles = StyleSheet.create({
  sectionContainer: {
    marginTop: 32,
    paddingHorizontal: 24,
  },
  sectionTitle: {
    fontSize: 24,
    fontWeight: '600',
  },
  sectionDescription: {
    marginTop: 8,
    fontSize: 18,
    fontWeight: '400',
  },
  highlight: {
    fontWeight: '700',
  },
});

export default App01;
